home *** CD-ROM | disk | FTP | other *** search
- /*********************************************************************
- File : GUSI - Grand Unified Socket Interface
- File : GUSIPAPTest - Test PAP sockets
- Author : Matthias Neeracher <neeri@iis.ethz.ch>
- Language : MPW C
-
- $Log: GUSIPAPTest.c,v $
- Revision 1.1 1994/02/25 02:47:26 neeri
- Initial revision
-
- *********************************************************************/
-
- #include <GUSI.h>
- #include <GUSITest.h>
- #include <stdio.h>
- #include <fcntl.h>
- #include <stdlib.h>
- #include <errno.h>
- #include <string.h>
-
- #include "Events.h"
-
- extern int GUSIDefaultSpin(spin_msg, long);
-
- void Open(char, char, const char *)
- {
- sock = open("Dev:Printer", O_RDWR);
-
- if (sock == -1) {
- printf("# open() returned error %s\n", Explain());
- Where();
- }
- }
-
- main(int argc, char ** argv)
- {
- printf("GUSIPAPTest MN 15Feb93\n\n");
-
- COMMAND('o', 'p', Open, "", "Open connection to printer");
-
- AddSocketCommands();
-
- GUSISetEvents(GUSISIOWEvents);
- RunTest(argc, argv);
- CleanupSockets();
- }